home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
HamCall (October 1991)
/
HamCall (Whitehall Publishing)(1991).bin
/
util
/
grab
/
deskjet.doc
next >
Wrap
Text File
|
1990-10-14
|
9KB
|
182 lines
The codes I have found in the manual for using the DeskJet are simple,
others have more elaborate methods. My codes are as follows:
Printer Type: Regular Printer
INIT String: 027 038 108 051 072 {This will feed the envelope}
EXIT String: 027 038 108 048 072 {This will eject the envelope}
Also change the locations where the information prints:
Up Down Location of the "FROM ADDRESS" -1
Left to Right Loc of the "TO ADDRESS" -8
Left to Right Loc of the "FROM ADDRESS" -5
The following is from two users of GRAB Plus that are using GRAB Plus along
with the DeskJet printer from Hewlett Packard. I do not personally
recommend the use of the DeskJet printer for envelopes because of the water
soluble ink that they use. - Paul Mayer, Author of GRAB Plus
----------------------------------------------------------------------------
The following narrative is being reprinted by permission of
T.L. Chadbourne [71320,501]. This in additive to my addendum should
enable one to successful use the Deskjet with soft fonts and Grab
Plus.
----------------------------------------------------------------------------
The DeskJet CAN be used to print very attractive envelopes with GRAB
Plus 5.1. It's not easy, but it is possible. I managed to convince Mr. Mayer
to increase the length of the printer INIT and EXIT strings to accommodate the
long escape sequences used by the DeskJet. I asked for 40 character strings,
and he came up with 32 characters, still not quite enough for my needs but
much better than the 8 characters of GRAB Plus 5.0.
If you want to skip the details, I've provided one basic set of INIT and
EXIT strings below which should give acceptable results. The rest of the
letter should help if you want to use the more attractive fonts. On the chance
that you might have a TmsRmn font cartridge, I've included a description of the
escape sequence I use with that cartridge.
What follows are the results of about 8 hours of experimentation.
1. GRAB Plus should be configured for a "regular printer" in the PRINTER menu
selection of GRABCFG.EXE.
2. In the same menu, select the "DO NOT FILTER" option to allow uploading of
the escape sequence which configures the DeskJet.
3. Use GRAB's INIT string to configure the printer for A4 paper. The DeskJet
cannot print return addresses directly against the left margin of a standard
#10 envelope. When configured for letter or legal size paper, or for a #10
envelope, the return address will be indented by a very noticeable 5/8". This
can be reduced to an acceptable 7/16" by configuring the printer for the
European A4 paper before printing, then switching back to the original paper
size settings using the printer reset code (Esc E) in the EXIT sequence.
4. Use GRAB's INIT string to disable perforation skip mode. If perforation
skip mode is enabled, the printer will execute three line feeds before
printing, pushing the return address unacceptably low, whatever GRAB's location
settings. The printer reset code (Esc E) must precede this code to allow it to
take effect with the first envelope printed.
If the escape sequence you choose is longer than 32 characters, it is
necessary to place the remainder of the INIT escape sequence in the first line
of the return address, as I describe in the next paragraph. This option is not
mentioned in GRAB's manual. If your sequence is 32 characters or less, you
don't need the technique, and can skip the paragraph.
To use an escape sequence longer than 32 characters, enter the first 32
characters in the INIT string as numerical ASCII values. Convert the rest of
the code to characters, not ASCII values; the HP manual lists both in most
cases. Select the option to use a return address, even if you don't actually
want to print one - the escape sequences won't be printed out, and there is no
convenient way to append them to a "To" address. With the cursor on the first
line of the address, enter the characters in the end segment of your escape
sequence. If you need to enter the escape code (ASCII 27), first press CTRL-P,
then press ESC. A bracket ("[") will appear against a black background,
different from the regular light background of the cursor. Next, press CTRL-P,
then CTRL-J. A "J" will appear, with a black background. Then type the first
line of the return address (probably your name) immediately following. The "J"
is a line feed (ASCII 10), which moves down the first line of the return
address, since the "Location" for "Up-Down Location, 'From' Address" in
GRABCFG.EXE MUST be set at 0, or GRAB will print line feeds after sending the
INIT string, and before printing the end of the escape sequence which is in the
return address. This breaks up the escape sequence, so it won't work. You may
add or delete CTRL-P CTRL-J's to change the up-down position of the return
address.
For Grab Plus 5.1, I recommend you start out with the following basic
escape sequence:
INIT: 27 69 27 38 108 50 54 97 48 76
EXIT: 27 69
This resets the printer (27 69), sets it for A4 paper (27 38 108 50 54
97), then disables perforation skip (48 76). The EXIT string resets the
printer to the defaults specified by the printer's function switches. These
escape sequences will allow you to position the return address as close to the
top left margin as possible. You do not need to select the option in
GRABCFG.EXE to print the INIT sequence after every line of text.
I have a TmsRmn ASCII font cartridge which I use for most printing, and
for all envelopes. While I am annoyed by the microspacing error in the
firmware for the lower-case "f" in 10 point type, I recommend the cartridge if
you don't already have it.
The escape sequence I use accesses a boldface 12 point proportionally
spaced Times Roman font, and prints it using line feed spacing of 1/5", instead
of the usual 1/6". On the chance that you have the cartridge, the sequence I
use is:
INIT: 27 69 27 38 108 53 100 50 54 97 48 76 27 40 48 85 27 40 115 48 117 49
112 49 50 118 48 115 48 98 53 116 50 81
EXIT: 27 69
For reference to the DeskJet manual, substituting "Ec" for the escape
code, the ASCII character counterpart to the INIT sequence above is:
INIT: Ec E Ec & l 5 d 2 6 a 0 L Ec ( 0 U Ec ( s 0 u 1 p 1 2 v 0 s 0 b 5 t 2 Q
You should be able to piece the elements of this code together from
your DeskJet manual. The escape sequences must be placed in the order
specified in the manual, and you can use HP's trick of combining sequences
which use the same two characters immediately following the escape code, using
a capital letter to terminate the combined sequences.
The problem with the above code is that it contains 34 characters, so it
won't all fit in GRAB's INIT string. The last two characters, "2Q", must go
into the first line of the return address, using the contortions I described
above.
The location settings I use for a large envelope are:
UD To 0
LR To 50
LR From -5
UD From 0
These settings depend on the use of the TmsRmn font cartridge, using the
escape sequence above; they will not be correct for the standard Courier font.
For 10 pitch Courier, try
UD To 1
LR To 0
LR From -5
UD From 1
I recommend pushing the envelope as far left as possible in the printer
before using the keypad controls to advance the letter. You can check the
envelope's alignment before printing.
If you've never dealt with escape sequences before, all this information
may seem a bit cryptic. The DeskJet manual chapters 4, 7, and the Appendix
provide a fairly good explanation. I hope you can modify my code to your own
specs without too much trouble.
---------------------------------------------------------------------------
ADDENDUM
For the record here is my GRABCFG configurations setting for the Helvette 12
point font:
1. Set print type to regular
2. INIT/EXIT Codes
Init String: 27 40 48 85 27 40 115 48 117 49 112 49 50 118 48 115
48 98 52 116 50 81 0 0 0 0 0 0 0 0 0 0
Do you want the Init to print before each line? [N]
Exit String: 27 69 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
[Note this represents the following Ascii String for downloading a 12pt
Helvette soft font: <Esc>(0U<Esc>(s0u1p12v0s0b4t2Q
For 12 point Times Roman use the following ASCII string and convert it to
the appropriate HEXIDECIMAL String for input into INIT code:
<Esc>(0U<Esc>(s0u1p12v0s0b5t2Q
This information provided by Gary Elfring]
3. Change Large and Small Envelope - Printer Locations
Large - The Up Down Location of the "To Address": -2
Large - The Left to Right Location of the "To Address": 55
Large - The Left to Right Location of the "From Address": -10
Large - The Up Down Location of the "From Address": -3
4. Download soft font to Deskjet prior to utilizing Grab.
-------------------------------------------------------------------------
Todd D. Fladen, M.D. [76555,643]